html command needed please?

Category: Geeks r Us

Post 1 by blbobby (Ooo you're gona like this!) on Tuesday, 10-Nov-2009 8:47:32

I am looking for a command the will let me enter html code on a web page withouot the browser executing it.

For example, "each html file begins with a <html> command.

Hope the editor here doesn't interpret this example. <lol>

Someone please help. I've done it before, but can't remember how.

Bob

Post 2 by LeoGuardian (You mean there is something outside of this room with my computer in it?) on Tuesday, 10-Nov-2009 11:21:46

Several ways to do this:
Assuming you meant what you said - include code as text in web page do this:
<xmp>
...some code ...
</xmp>
That's old, still works but may not be supported.
Of course you can surround it with <pre> and inside that <code> tags.
You can also use html entities
< >
You could always script this in JavaScript or PERL or whatever.
But xmp is supported even in IE8 I just checked - but I don't know if you can style it; presumably you could.
If you want to make it defined in a space / scrollable use textarea - you can size and style that however you want.

I'm just dropping this in as I go so it's just a pointer to get you started

Post 3 by Grace (I've now got the ggold prolific poster award! wahoo! well done to me!) on Tuesday, 10-Nov-2009 13:04:08

quite an answer there robozork
{now "if only" I could be given to
understand your response..
Your response is probably more than fine
..it is just that Bob has a way of questions
that give me puzzlement}

html facinates me

BOTH html and Bob I find to
be challenging!!

Keep Up the Great Work
&LT;&LT;smiles>>

Post 4 by malthe (Pimply-Faced Youth) on Tuesday, 10-Nov-2009 16:12:10

I will type it out with words so you can see how it is done, then write an exmaple below:
Say you wanted to type out a tag that should be seen on the page like this: